const customs = {}

;(function(ctx){
  ctx.keys().forEach(key => {
    const keys = key.split('/')

    const filename = keys[keys.length - 1].split('.')[0]

    const data = ctx(key).default

    if(data) {
      const name = data.name || filename
      customs[name] = {
        clazzType: 'custom',
        showName: '自定义调试:' + name,
        version: name,
        ...data
      }
    }
  })
})(require.context('debug', true, /\.(js|ts)x?$/)) 


export default customs
